import 'package:effective/generated/json/base/json_convert_content.dart';

class ResultEntity<T> with JsonConvert<ResultEntity> {
	int code;
	String message;
	T data;

	ResultEntity(){}

	ResultEntity.success(T data){
		this.code = 200;
		this.message = "success";
		this.data = data;
	}

	ResultEntity.error(int code,String msg,{T data}){
		this.code = code;
		this.message = msg;
		this.data = data ?? '';
	}
}
